package drds.global_transaction.api.message_codec;

public enum ResponseCode
{

	failed, success;

	public static ResponseCode get(byte ordinal)
	{
		return get((int) ordinal);
	}

	public static ResponseCode get(int ordinal)
	{
		for (ResponseCode responseCode : ResponseCode.values())
		{
			if (responseCode.ordinal() == ordinal)
			{
				return responseCode;
			}
		}
		throw new IllegalArgumentException("unknown ResponseCode[" + ordinal + "]");
	}
}
